package com.hrms.doctor.mapper;

import com.hrms.doctor.domain.Message;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.time.LocalDateTime;
import java.util.List;

@Mapper
public interface MessageMapper {
    Integer insertDoctorMessage(Message message);
    Integer insertPatientMessage(Message message);
    List<Message> selectMessage(@Param("doctorId") Long doctorId, @Param("patientId") Long patientId);
    List<Message> selectMessageInPatient(@Param("doctorId") Long doctorId, @Param("patientId") Long patientId);
    Integer delete(@Param("doctorId") Long doctorId,@Param("patientId") Long patientId,@Param("createTime") LocalDateTime createTime);
    void update(Message message);
    void updatePatient(Message message);
    Integer countPatient();
    Integer countDoctor();

    List<Message> getDoctor(@Param("doctorId") Long doctorId, @Param("patientId") Long patientId);
    List<Message> getPatient(@Param("doctorId") Long doctorId, @Param("patientId") Long patientId);


}
